execute unless entity @s[distance=..6] run return 1
execute if block ~ ~ ~ #minecraft:air unless block ^ ^ ^0.1 #minecraft:air align xyz positioned ~0.5 ~ ~0.5 run function faqv:villager_ball/try_spawn_villager
execute positioned ^ ^ ^0.1 run function faqv:villager_ball/try_create_villager